package com.zzyy.study.config;

import com.zzyy.study.lock.DefaultDistributeLock;
import com.zzyy.study.lock.DistributeLock;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @auther zzyy
 * @create 2024-07-14 15:24
 */
@Configuration
public class DistributeLockConfiguration
{
    @Bean
    @ConditionalOnMissingBean
    public DistributeLock distributeLock()
    {
        return new DefaultDistributeLock();
    }
}


